<template>
  <h3>vue3の生命周期</h3>
  <h4>数据{{ conut }}</h4>
  <button @click="updateFn">点我更新数据</button>
</template>
<script setup lang="ts">
import { ref, onBeforeMount, onMounted, onBeforeUpdate, onUpdated, onBeforeUnmount, onUnmounted } from 'vue'

let conut = ref(0)
const updateFn = () => {
  conut.value ==
}

//加了一些内容
//vue3中 setup 包含了berfoCreacd Created 
onBeforeMount(() => {
  console.log('挂载前');
})
onMounted(() => {
  console.log('挂载后');
})
onBeforeUpdate(() => {
  console.log('更新前');

})
onUpdated(() => {
  console.log('更新后');

})

onBeforeUnmount(() => {
  console.log('销毁前');

})

onUnmounted(() => {
  console.log('销毁后');

})


</script>
